<?php
// phpinfo();exit;
try{
	define('N_DEBUG', 0);						

	include 'core/Init.php';
	//n_api("debug")->set('public');	//[0:dev,1:test,2:alpha,3:beat,4:public]

	$n = new Controller();
	n_api("install")->check();
	if(!in_array(N_EVENT,array("open","error","install")) && N_SCRIPT!='cli'){
		n_api("passport")->startSession();
		//n_api("manager")->reloadPrivate();
	}
	$n->run();

	
}catch(CException $c){
	n_fault($c);

}catch(PException $p){
	n_alert($p);

}catch(exception $e){
	n_ufo($e);

}

